package miracle.joker.design.decorator;

public class CompressionDecorator implements FileAccess {
    private FileAccess fileAccess;

    public CompressionDecorator(FileAccess fileAccess) {
        this.fileAccess = fileAccess;
    }

    public void read(String fileName) {
        fileAccess.read(fileName);
    }

    public void write(String fileName) {
        System.out.println("Compressing file: " + fileName);
        fileAccess.write(fileName);
    }
}
